package com.wkbb.sports.enums;

/**
 * @author liuxiancan
 */
public enum SportsRuleTypeEnum {

    DESC(2,"降序"),
    ASC(1,"升序");

    private SportsRuleTypeEnum(Integer value, String desc) {
        this.value = value;
        this.desc = desc;
    }

    private Integer value;

    private String desc;

    public Integer getValue() {
        return this.value;
    }

    public void setValue(Integer value) {
        this.value = value;
    }

    public String getDesc() {
        return this.desc;
    }

    public void setDesc(String desc) {
        this.desc = desc;
    }

    public static String getDesc(Integer value) {
        for (SportsRuleTypeEnum fileType : SportsRuleTypeEnum.values()) {
            if (fileType.getValue().intValue()==value) {
                return fileType.getDesc();
            }
        }
        return null;
    }
}
